[slug].vue 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. <script lang='ts' setup>
  2. import { useCommonStore } from '@/stores/modules/common'
  3. const commonStore = useCommonStore()
  4. const list = [
  5. {
  6. id: 1,
  7. title: 'Stationary & Office Supplies',
  8. description: 'Discover bestsellers and fresh arrivals tailored to your niche.',
  9. img: 'https://picsum.photos/560/310',
  10. },
  11. {
  12. id: 2,
  13. title: 'Stationary & Office Supplies',
  14. description: 'Discover bestsellers and fresh arrivals tailored to your niche.',
  15. img: 'https://picsum.photos/560/310',
  16. },
  17. {
  18. id: 3,
  19. title: 'Stationary & Office Supplies',
  20. description: 'Discover bestsellers and fresh arrivals tailored to your niche.',
  21. img: 'https://picsum.photos/560/310',
  22. },
  23. {
  24. id: 4,
  25. title: 'Stationary & Office Supplies',
  26. description: 'Discover bestsellers and fresh arrivals tailored to your niche.',
  27. img: 'https://picsum.photos/560/310',
  28. },
  29. ]
  30. const { openLoginAndDownloadModal } = useLoginAndDownLoadModal()
  31. async function clickLoginAndDownload(item: any) {
  32. try {
  33. commonStore.setDownloadCatalog(item)
  34. const { status } = await openLoginAndDownloadModal()
  35. if (status)
  36. location.reload()
  37. }
  38. catch (error) {
  39. console.log(error)
  40. }
  41. }
  42. </script>
  43. <template>
  44. <div>
  45. <div class=" bg-#0F0820">
  46. <div class="header w-1200-auto text-center flex items-center justify-center h-600px bg-no-repeat bg-center" style="background-image: url('https://picsum.photos/420/420')">
  47. <h1 class="text-58px fw-800 text-#fff ls-2 custom-title-font">
  48. STATIONARY & OFFICE SUPPLIES
  49. </h1>
  50. </div>
  51. </div>
  52. <div class="py-120px w-1200-auto text-center">
  53. <h2 class="text-36px fw-800 text-#333 !mb-20px custom-title-font">
  54. Our Latest Product <span class="custom-title-bg04">Catalogs</span>
  55. </h2>
  56. <div class="text-#999 text-22px mb-40px">
  57. Discover bestsellers and fresh arrivals tailored to your niche.
  58. </div>
  59. <div class="grid grid-cols-2 gap-64px text-left">
  60. <div v-for="item in list" :key="item.id">
  61. <business-categories-comp-item :item="item" @select="clickLoginAndDownload" />
  62. </div>
  63. </div>
  64. </div>
  65. <common-block-catalogs />
  66. <common-block-blog class="!pb-0" />
  67. <AppFooter />
  68. </div>
  69. </template>
  70. <style lang='less' scoped>
  71. .header{
  72. background-position: 50% 75%;
  73. }
  74. </style>